<div class="col-xs-12 col-md-8">
    <div class="messages-user">
        <h3 class="title red"><i class="fa fa-inbox"></i> <?php echo lang_system('user_inbox_label') ?></h3>
        <div class="messages-list">

            <?php if (!$messages): ?>
                <ul>
                    <li class="no-messages-box"> <?php echo lang_system('user_no_messages_inbox') ?> </li>
                </ul>
            <?php endif; ?>

            <?php if ($messages): ?>
                <table class="table table-mailbox">
                    <tbody>
                        <tr class="header-mailbox">
                            <th><?php echo lang_system('mailinbox_by'); ?></th>
                            <th><?php echo lang_system('mailinbox_subject'); ?></th>
                            <th></th>
                        </tr>
                    
                    
                        <?php foreach ($messages as $item): ?>
                            <tr class="<?php echo $item->LOADED == 'S' ? '' : 'unread'; ?>">
                                <td class="col-md-4"><strong><?php echo $item->SENDING; ?></strong> </td> 
                                <td class="col-md-6"> 
                                    <span><i class="fa fa-exclamation-circle"></i> <?php echo $item->TITLE; ?> 
                                    </span>
                                </td>
                                <td class="small-col">
                                    <a data-trigger-fancybox data-url="<?php echo site_url('load-messsage-private-'.$item->ID.'.html'); ?>" class="pull-right link-priview" href="#"><i class="fa fa-eye"></i></a>
                                </td>
                            </tr>
                        <?php endforeach; ?>
                    </tbody>

                </table>          
            <?php endif; ?>



        </div>
    </div>
</div>
<div class="col-xs-12 col-md-4">
    <div class="messages-user">
        <h3 class="title blue"><i class="fa fa-legal"></i> <?php echo lang_system('user_next_auctions'); ?></h3>
        <div class="message-box">
            <?php if ($leiloes): ?>
                <ul class="todo-list">
                    <?php foreach ($leiloes as $row): ?>
                    <li class="">
                        <span class="header-info">
                        <span class="label label-success"><?php echo auto_format_data($row->DATA, '-', '/'); ?>
                          
                        </span> 
                            <a data-id="<?php echo $row->ID; ?>" 
                               data-trigger-fancybox data-url="<?php echo site_url('home/PrintCatalogo_ajax'); ?>"
                               class="link"title="<?php echo lang_system('user_title_show_list_itens'); ?>" href="#"><i class="fa fa-print"></i></a> | 
                            <a data-trigger-fancybox data-url="<?php echo site_url('home/get_condicoes_pagamento'); ?>" data-id="<?php echo $row->ID; ?>" class="link" title="<?php echo lang_system('user_title_show_conditions'); ?>" href="#"><i class="fa fa-legal"></i></a> 
                        </span>    
                            <a href="<?php echo site_url('lotes-leilao/'.$row->ID); ?>">
                         <?php  echo $row->TITLE;?></a></li>
                    <?php endforeach; ?>
                </ul>
            <?php endif; ?>
            <?php if (!$leiloes): ?>
                <ul>
                    <li class="no-messages-box"> <?php echo lang_system('no_data') ?> </li>
                </ul>
            <?php endif; ?>

        </div>

    </div>
</div>
<?php 

add_js('scripts/user/jquery.home', 'footer', 13);
add_js('plugins/frontend/jquery.mousewheel.min', 'footer', 11);
add_js('plugins/frontend/jquery.jqzoom-core', 'footer', 11);
add_js('plugins/frontend/fancybox/jquery.fancybox', 'footer', 6);
add_js('plugins/frontend/fancybox/jquery.fancybox-buttons', 'footer', 9);
add_js('plugins/frontend/fancybox/jquery.fancybox-media', 'footer', 9);
add_js('plugins/frontend/fancybox/jquery.fancybox-thumbs', 'footer', 9);
add_js('plugins/frontend/jquery.maskMoney', 'footer', 9);

add_css('frontend/fancybox/jquery.fancybox', 'header', 13);
add_css('frontend/fancybox/helpers/jquery.fancybox-buttons', 'header', 14);
add_css('frontend/fancybox/helpers/jquery.fancybox-thumbs', 'header', 15);
add_css('frontend/jquery.jqzoom', 'footer', 16);
